package com.swj.common.core.model.web;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.stereotype.Component;

import java.io.Serializable;

/**
 * @author 10834
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Component
public class RestResult<T> implements Serializable {

    /**
     *  状态码
     */
    private Integer code;

    /**
     *  提示信息
     */
    private String msg;

    /**
     *  服务器异常信息
     */
    private String error;

    /**
     *  成功返回的数据
     */
    private T data;
}
